﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using BE.Abastos;

namespace SAIN.Abastos.catalogo
{
    public partial class Productos : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!this.IsPostBack)
            {
                DDLMedida.Items.Clear();
                List<BE.Abastos.Measures> lista = new List<BE.Abastos.Measures>();

                lista = new BC.Abastos.MeasuresBC().Select(new BE.Abastos.Measures()
                {
                    iMeasureId = -1,
                    sMeasureName = string.Empty
                });

                DDLMedida.Items.AddRange(
                    (from o in lista
                     select new ListItem(o.sMeasureName, o.iMeasureId.ToString())).ToArray<ListItem>());
            }
        }

        protected void btnCrearProducto_Click(object sender, EventArgs e)
        {

        }
    }
}